//package com.lis.scf.controller;
//package com.enterprise.controller;
//
//import com.enterprise.dto.EnterpriseInfoDTO;
//import com.enterprise.dto.ResponseDTO;
//import com.enterprise.service.EnterpriseService;
//import com.enterprise.service.RealNameAuthService;
//import lombok.RequiredArgsConstructor;
//import org.springframework.security.access.prepost.PreAuthorize;
//import org.springframework.web.bind.annotation.*;
//import org.springframework.web.multipart.MultipartFile;
//
///**
// * 企业管理控制器
// * 处理企业信息完善、实名认证等功能
// */
//@RestController
//@RequestMapping("/enterprise")
//@RequiredArgsConstructor
//public class EnterpriseController {
//
//    private final EnterpriseService enterpriseService;
//    private final RealNameAuthService authService;
//
//    /**
//     * 完善企业信息
//     */
//    @PostMapping("/complete-info")
//    @PreAuthorize("isAuthenticated()")
//    public ResponseDTO<String> completeInfo(@RequestBody EnterpriseInfoDTO dto) {
//        enterpriseService.completeEnterpriseInfo(dto);
//        return ResponseDTO.success("企业信息完善成功");
//    }
//
//    /**
//     * 实名认证第一步：提交银行账户信息
//     */
//    @PostMapping("/auth/bank-info")
//    @PreAuthorize("isAuthenticated()")
//    public ResponseDTO<String> submitBankInfo(@RequestParam Long companyId,
//                                              @RequestParam String bankAccount,
//                                              @RequestParam String bankName) {
//        authService.submitBankInfo(companyId, bankAccount, bankName);
//        return ResponseDTO.success("银行信息提交成功，请等待打款验证");
//    }
//
//    /**
//     * 实名认证第二步：验证打款金额
//     */
//    @PostMapping("/auth/verify-amount")
//    @PreAuthorize("isAuthenticated()")
//    public ResponseDTO<String> verifyAmount(@RequestParam Long companyId,
//                                            @RequestParam String amount) {
//        authService.verifyAmount(companyId, amount);
//        return ResponseDTO.success("实名认证通过");
//    }
//
//    /**
//     * 上传认证资料
//     */
//    @PostMapping("/auth/upload-docs")
//    @PreAuthorize("isAuthenticated()")
//    public ResponseDTO<String> uploadDocuments(@RequestParam Long companyId,
//                                               @RequestParam String docType,
//                                               @RequestParam MultipartFile file) {
//        String filePath = enterpriseService.uploadDocument(companyId, docType, file);
//        return ResponseDTO.success("文件上传成功", filePath);
//    }
//}
